|
|
|
| Command | Query Type | Table | Column | | | | Order Date | | cmdOrderDetail | Table | Order Details | <All Columns> | | cmdEmployees | Table | Employees | <All Columns> |
|
|
|
|
|
|
In preparation for the remaining sections of this chapter, start a new project with a single default form in it. |
|
|
|
|
|
|
|
|
To define the database connection, add a Data Environment Object by right-clicking in the Project Explorer and choosing Add from the pop-up menu. Then choose More ActiveX Designers, the Data Environment as shown in Figure 12.1. |
|
|
|
|
|
|
|
|
Figure 12.1.
Adding a Data Environment Designer to the application by using
the pop-up menu in the Project Explorer. |
|
|
|
|
|
|
|
|
After the new Data Environment object is added to your project, right-click the Connection1 object and choose Properties to display the Connection Properties dialog. The steps defining a connection are very close to the ones used for the ActiveX Data control. When defining the connection, you can choose from either a direct connection to a Jet-supported database, a standard ODBC connection, or one of several OLE DB providers. OLE DB is the latest technique for accessing a database and provides you access to more database-supported features. On the Data Link Properties dialog (see |
|
|
|
|
|